﻿Imports BL.BL


Public Class frmChequeoRecalculoDV

#Region "Métodos"


    Private Sub frmChequearIntegridadDV_Load(sender As Object, e As EventArgs) Handles MyBase.Load

        'si hay falla de integridad de BD (tablas usuario_familia ó usuario_patente) - no seteamos patentes
        If frmPrincipal.integridad = True And frmPrincipal.usr.nick <> "suseas" Then
            'patentes del usuario logueado.
            Helper_FL.setearPermisos(frmPrincipal.usr, Me)
        End If

    End Sub


    Public Sub ChequearDV(sender As Object, e As EventArgs) Handles btnChequearDV.Click
        If Helper_BL.chequearDV(False) = True Then
            MsgBox("Se verificó la Integridad de las Tablas y no se encontraron errores..", MsgBoxStyle.Information, "")
        End If

    End Sub


    Private Sub btnRecalcularDV_Click(sender As Object, e As EventArgs) Handles btnRecalcularDV.Click
        Helper_BL.recalcularTodosLosDV()
    End Sub


    Private Sub Salir_Click(sender As Object, e As EventArgs) Handles btnSalir.Click
        Me.Close()
        Me.Dispose()
    End Sub


#End Region

#Region "Métodos auxiliares"

    Private Sub frmChequeoRecalculoDV_KeyDown(sender As Object, e As KeyEventArgs) Handles MyBase.KeyDown
        If e.KeyCode = Keys.F1 Then
            Help.ShowHelp(Me, Application.StartupPath & "\ayuda_SEAS.chm", "chequeardv.htm")
        End If
    End Sub

#End Region


End Class


